﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;

namespace ass5Vinyl.CONTROLLER
{
    class Customers
    {
       
        public Customers() { }

        public string InsertCustomer(Customer c)
        {
            DataTable customerExist = DataQueries.customerExist(c.cId.ToString(), "customer");
            if (customerExist.Rows.Count > 0)
                return "customer Num. " + c.cId + " is already exist in the system ";

            DataQueries.InsertCostumer(c, "customer");
            return "customer was add successfully";
        }

    }
    public struct Customer
    {
        public int cId;
        public string cName;
        public string CLastName;
        public string cAdderess;
        public string cPhone;
        public string cBirthDay;
    }
    
}
